
package tomkitty.util;

import tomkitty.server.*;
import tomkitty.turdlet.*;

/**
 *
 * The EventSource interface provides methods for registering and
 * deregistering EventListeners. Classes implementing this interface
 * may use the EventListenerCollection class to keep track of registered
 * listeners.
 *
 * @author micha
 *
 */
public interface EventSource {
	
	/**
	 *
	 * Adds an EventListener to the list of registered listeners. Each event
	 * will be sent to all registered listeners.
	 *
	 * @param listener the EventListener to register.
	 */
	public void addListener(EventListener listener);

	/**
	 *
	 * Deregisters an EventListener.
	 *
	 * @param listener the EventListener to deregister.
	 */
	public void removeListener(EventListener listener);
		
}
